Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#107: Swift Package Manager support #109

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

JakubMazur
Copy link

@JakubMazur JakubMazur commented Jul 17, 2021

Swift Package Manager Support #107

Swift Package Manager added to both Rx and main target.

  • check pod spec lint
  • check carhage build --archive
  • swift build for iOS target
  • update installation README

Known issues:

  1. AppSwizzle that frameworks is using as test target does not support SPM yet. I open PR with support to SPM there, but project looks abandoned. SPM test target has then dependency to my fork of this project with SPM Support
  2. Currently SPM has a limitation that will resolve all dependencies that Package incudes for any target (not test target) described here as partialy implemented. There is no negative impact on a project exept the fact that the user that is not using Rx version will see resolved package in Xcode that will not be linked to a binary later or usable in a project. Here is my StackOverflow question on this topic that leads me to open ticket SR-8658. AFAIK there is no walkaround for it.

TODO:

#108: after merge and tag a new version update a package to Swift Package Index

* add Package.swift

* Update Package.swift

* scheme build

* add Rx support

* rename from "+"

* set empty dependencies for main target

* update readme
@codecov
Copy link

codecov bot commented Jul 17, 2021

Codecov Report

Merging #109 (2c539e6) into master (0479b14) will decrease coverage by 1.83%.
The diff coverage is n/a.

❗ Current head 2c539e6 differs from pull request most recent head 6de3b67. Consider uploading reports for the commit 6de3b67 to get more accurate results

@@            Coverage Diff             @@
##           master     #109      +/-   ##
==========================================
- Coverage   97.80%   95.97%   -1.84%     
==========================================
  Files           8        8              
  Lines         273      273              
==========================================
- Hits          267      262       -5     
- Misses          6       11       +5     
Impacted Files Coverage Δ
ReCaptcha/Classes/ReCaptchaError.swift 73.91% <0.00%> (-21.74%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0479b14...6de3b67. Read the comment docs.

@JakubMazur
Copy link
Author

@fjcaetano you have any idea why codecov showing this? there was no change in this file that could impact coverage in this configuration

@fjcaetano
Copy link
Owner

@JakubMazur I apologize for the delay. I tried taking a quick look at this a few days back, but I was having issues when I tried refactoring the Examples project to leverage SPM instead of Cocoapods. I wasn't able to install the package locally, like Cocoapods does with pod 'ReCaptcha/RxSwift', :path => '../'

I'll try to get back to this soon when I'm a bit more free. In the mean time, don't worry about Codecov. It's complaining because this PR reduces code coverage, but that's expected since you're adding config files that aren't testable.

@JakubMazur
Copy link
Author

If you want to switch example project to use SPM instead of Cocoapods I can have a look and submit code changes to this PR

* process recaptcha.html

* use module
@JakubMazur JakubMazur marked this pull request as draft September 27, 2021 18:54
@andrewtheis
Copy link

andrewtheis commented Oct 19, 2021

@fjcaetano You can drag the folder containing Package.swift directly into the Xcode Project to locally reference the package.

@haemi
Copy link

haemi commented Mar 12, 2022

what's the latest state regarding SPM support? Is there a way/branch/... to use ReCaptcha with SPM?

* process recaptcha.html

* use module
@JakubMazur
Copy link
Author

@haemi you can use my fork: master branch on https://github.com/JakubMazur/ReCaptcha

but unsure if this will work with Cocoapods as in discussion above. Although it is working with SPM

@mccarron
Copy link

mccarron commented May 6, 2022

@fjcaetano Anything we can do to help push this through? One of the last packages not moved over to SwiftPM yet for us.

@emrcftci
Copy link

any updates on this? @fjcaetano

@o15a3d4l11s2
Copy link

Any updates on the SPM implementation?

@anivaros
Copy link

anivaros commented Feb 9, 2024

@fjcaetano Anything we can do to help push this through?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants